home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / kcanvasrootpixmap.h < prev    next >
Encoding:
C/C++ Source or Header  |  2005-10-10  |  1.7 KB  |  62 lines

  1. /*
  2.     This file is part of the KDE games library
  3.     Copyright (C) 2001,2002,2003 Nicolas Hadacek (hadacek@kde.org)
  4.  
  5.     This library is free software; you can redistribute it and/or
  6.     modify it under the terms of the GNU Library General Public
  7.     License version 2 as published by the Free Software Foundation.
  8.  
  9.     This library is distributed in the hope that it will be useful,
  10.     but WITHOUT ANY WARRANTY; without even the implied warranty of
  11.     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  12.     Library General Public License for more details.
  13.  
  14.     You should have received a copy of the GNU Library General Public License
  15.     along with this library; see the file COPYING.LIB.  If not, write to
  16.     the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  17.     Boston, MA 02110-1301, USA.
  18. */
  19.  
  20. #ifndef KCANVASROOTPIXMAP_H
  21. #define KCANVASROOTPIXMAP_H
  22.  
  23. #include <krootpixmap.h>
  24. #include <kdemacros.h>
  25.  
  26. class QCanvasView;
  27.  
  28. /**
  29.  * Implement KRootPixmap for a QCanvasView.
  30.  *
  31.  * The pixmap will be set as the background of the
  32.  * QCanvas associated with the view :
  33.  * <ul>
  34.  * <li>for correct positioning of the background pixmap, the given
  35.  * QCanvasView should be positioned at the origin of the canvas.</li>
  36.  * <li>no other view of the same canvas should use KCanvasRootPixmap.</li>
  37.  * <li>other views of the canvas will have the same background pixmap.</li>
  38.  * </ul>
  39.  */
  40. class KDE_EXPORT KCanvasRootPixmap : public KRootPixmap
  41. {
  42.  Q_OBJECT
  43.  
  44.  public:
  45.     /**
  46.      * Constructor.
  47.      */
  48.     KCanvasRootPixmap(QCanvasView *view, const char *name = 0);
  49.  
  50.  private slots:
  51.     void backgroundUpdatedSlot(const QPixmap &);
  52.  
  53.  private:
  54.     QCanvasView *_view;
  55.  
  56.     class KCanvasRootPixmapPrivate;
  57.     KCanvasRootPixmapPrivate *d;
  58. };
  59.  
  60. #endif
  61.  
  62.